﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<WRSManagementSystem.DomainModel.Entities.Person>" %>
<%@ Import Namespace="WRSManagementSystem.DomainModel.Entities" %>
<fieldset>
    <legend>Osoba</legend>
    <table>
        <tr>
            <th>
                Imię
            </th>
            <th>
                Nazwisko
            </th>
            <th>
                Funkcja
            </th>
            <th>
                E-mail
            </th>
            <th>
                Telefon
            </th>
        </tr>

        <tr>
            <td>
                    <%=Html.Encode(Model.Name)%>
            </td>
            <td>
                    <%=Html.Encode(Model.Surname)%>
            </td>
            <td>                    
                    <%
                        foreach (Function item in Model.Functions)
                        {%>
                    <div>
                        <%=Html.Encode(item.Description)%>
                    </div>
                    <%
                        }%>
            </td>
            <td>
                    <%=Html.Encode(Model.Email.mail)%>
            </td>
            <td>
                    <%=Html.Encode(Model.Phone.PhoneNumber)%>
            </td>
        </tr>
    </table>
</fieldset>
